
public class Trans 
{
	private double prob=0.0;
	private String Symb= "";
	private String cod="";
	
  public Trans(String s, double p) 
    {
    	prob = p;
    	Symb = s;
    }
  public Trans() 
  {
  }

  public void setProb(double p)
  {
   	prob = prob+p;
  }
  
  public void setCod(String c)
  {
   	cod=c+cod;
  }
   	
  public void setSim(String s)
  {
   	Symb=Symb+s;
  }
  
  public String getCod()
  {
   	return cod;
  }
   	
  public double getProb()
  {
   	return prob;
  }
   	
  public String getSymb()
  {
   	return Symb;
  }
   
  public String toString()
  {
   	return (Symb + " probabilidad = " + prob + " posee el codigo = "+ cod + "\n");
  }
    
  public boolean equals(Object o)
  {
    Trans s = (Trans) o;
     if(s.getSymb().equals(Symb))
    		return true;
    	return false;
  }
}